﻿using Ledict.ConditionExtract.Base;
using Ledict.ConditionExtract.Controls;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace Ledict.ConditionExtract.Frm
{
    public partial class FrmCondition : BaseForm
    {
        public string Condition { get; set; }
        SelectWindowNew sw;
        public FrmCondition(string str)
        {
            InitializeComponent();
            sw = new SelectWindowNew(str);
            sw.Left = 0;
            sw.Top = 3;
            sw.Dock = DockStyle.Fill;
            panel1.Controls.Add(sw);
        }

        private void button1_Click(object sender, EventArgs e)
        {
            string strs = sw.GetDataString();
            Condition = strs;
            if (string.IsNullOrEmpty(Condition) || Condition == "请添加完整信息")
            {
                return;
            }
            this.DialogResult = DialogResult.Yes;
            this.Close();
        }

        private void Form3_Load(object sender, EventArgs e)
        {

        }
    }
}
